﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

using System.Windows.Input;



namespace HA.ModFlow.Application
{

   


   public class RibbonViewModelV2:HViewModel
   {

       public RibbonViewModelV2()
       {

           this._recentViewModel = new RecentProjectViewModel();

           this._minGridVM = new MiniGridViewModel(null);

       }


       //之后的设计里，分为项目变更部分，和项目不变部分

       RecentProjectViewModel _recentViewModel;

       public RecentProjectViewModel RecentViewModel
       {
           get { return _recentViewModel; }
           set { _recentViewModel = value; }
       }


       RViewOperationViewModel _viewOpViewModel;

       public RViewOperationViewModel ViewOpViewModel
       {
           get { return _viewOpViewModel; }
           set { _viewOpViewModel = value; }
       }


       MiniGridViewModel _minGridVM;

       public MiniGridViewModel MinGridVM
       {
           get { return _minGridVM; }
           set
           {

               _minGridVM = value;

               this.OnPropertyChanged("MinGridVM");

           }
       }




       public void OnResetProject()
       {

           if (!ProjectService.DefaultService.BNullProj)
           {
               this._viewOpViewModel = new RViewOperationViewModel();

               this.MinGridVM = this._viewOpViewModel.MinGridVM;
               
           }
           else
           {
               this.MinGridVM = new MiniGridViewModel(null);
           
           }

       





           this.OnPropertyChanged("ViewOpViewModel");

        
          
 
       }




   

   }
}
